﻿<%@ Page Language="C#" MasterPageFile="~/cp/admin/AdminMasterPage.master" AutoEventWireup="true" Inherits="cp_admin_site_management" Title="Thông tin công ty" Codebehind="management.aspx.cs" ErrorPage="~/Common/Error.aspx" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="body" Runat="Server">
    <asp:DetailsView ID="detailCompanyInfo" runat="server" Height="50px" Width="100%" 
        AutoGenerateRows="False" CellPadding="4" DataSourceID="dataCompany" 
        ForeColor="#333333" GridLines="None" EditRowStyle-Width="100%" 
        Caption="Thông tin công ty" EmptyDataText="Không tìm thấy thông tin" 
        EnableModelValidation="True">
        <FooterStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
        <CommandRowStyle BackColor="#D1DDF1" Font-Bold="True" />
        <RowStyle BackColor="#EFF3FB" />
        <FieldHeaderStyle BackColor="#DEE8F5" Font-Bold="True" />
        <PagerStyle BackColor="#2461BF" ForeColor="White" HorizontalAlign="Center" />
        <Fields>
            <asp:BoundField DataField="Name" HeaderText="Tên công ty" 
                SortExpression="Name" >
                <ControlStyle Width="90%" />
            </asp:BoundField>
            <asp:BoundField DataField="Email" HeaderText="Email" SortExpression="Email" >
                <ControlStyle Width="90%" />
            </asp:BoundField>
            <asp:BoundField DataField="Phone" HeaderText="Điện thoại" 
                SortExpression="Phone" >
                <ControlStyle Width="90%" />
            </asp:BoundField>
            <asp:BoundField DataField="Address" HeaderText="Địa chỉ" 
                SortExpression="Address" >
                <ControlStyle Width="90%" />
            </asp:BoundField>
            <asp:BoundField DataField="LastUpdate" HeaderText="Ngày cập nhật" 
                SortExpression="LastUpdate" ReadOnly="True" />
            <asp:BoundField DataField="UserUpdate" HeaderText="Người cập nhật" 
                SortExpression="UserUpdate" ReadOnly="True" />
            <asp:BoundField DataField="Banner" HeaderText="Banner" 
                SortExpression="Banner" >
                <ControlStyle Width="90%" />
            </asp:BoundField>
            <asp:CommandField ButtonType="Button" CancelText="Hủy" EditText="Sửa" 
                ShowEditButton="True" UpdateText="Cập nhật" />
        </Fields>
        <HeaderStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
        <EditRowStyle BackColor="#2461BF" Width="100%" Wrap="True" />
        <AlternatingRowStyle BackColor="White" />
    </asp:DetailsView>
    <asp:ObjectDataSource ID="dataCompany" runat="server" 
        SelectMethod="GetCompanyInfo" 
        TypeName="E2_WEBSITE.Code.Admin.CompanyController" 
        UpdateMethod="UpdateCompanyInfo">
        <UpdateParameters>
            <asp:Parameter Name="Name" Type="String" />
            <asp:Parameter Name="Email" Type="String" />
            <asp:Parameter Name="Phone" Type="String" />
            <asp:Parameter Name="Address" Type="String" />
            <asp:Parameter Name="Banner" Type="String" />
        </UpdateParameters>
    </asp:ObjectDataSource>
</asp:Content>
<asp:Content ID="Content3" runat="server" contentplaceholderid="info">
Quản lý, cập nhật thông tin cho công ty.   
</asp:Content>
